package com.youcai.springboot_day02.controller;

import org.springframework.stereotype.Controller;
import org.springframework.ui.Model;
import org.springframework.web.bind.annotation.RequestMapping;

import java.util.ArrayList;
import java.util.Arrays;

@Controller
public class HelloController {

    @RequestMapping("/aa")
    public String hello(Model model){
        model.addAttribute("aaa1","<h1>bbb1</h1>");
        model.addAttribute("aaa2","<h1>bbb2</h1>");
        model.addAttribute("list", Arrays.asList("aa","bb"));
        return "index";
    }

}
